package fr.curriculumvitae.anthony.stephan;

import com.parse.Parse;
import com.parse.ParseInstallation;
import com.parse.PushService;

import fr.curriculumvitae.anthony.stephan.constants.ParseConstants;
import android.app.Application;
import android.content.Context;

public class CVApplication extends Application {
	
	private static CVApplication instance = new CVApplication();

	public CVApplication() {
		instance = this;
	}

	public static Context getContext() {
		return instance;
	}

	@Override
	public void onCreate() {
		super.onCreate();
		Parse.initialize(this, ParseConstants.APPLICATION_ID, ParseConstants.CLIENT_KEY);
		PushService.setDefaultPushCallback(this, SwipeyTabsActivity.class);
		ParseInstallation.getCurrentInstallation().saveInBackground();
	}
	
}
